// The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias.
import Vue from 'vue'
import App from './App'
import router from './router'
import store from './store'
import api from './util/http/api'

// 自定义安装Vue prototype
const install = Vue => {
  // 挂载在原型上
  Vue.prototype.$api = api
  // 挂载静态方法
  Vue.$api = api
}
Vue.use({
  install
})

Vue.config.productionTip = false

/* eslint-disable no-new */
new Vue({
  el: '#app',
  router,
  store,
  components: { App },
  template: '<App/>'
})
